package com.mtung.cosumer.controller;

import com.alibaba.nacos.api.config.annotation.NacosValue;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author zhenguo.yao
 * @date 2020/12/11
 */
@RestController
@RequestMapping("/config")
public class ConfigController {

    @NacosValue(value = "${mtung.name}",autoRefreshed = true)
    private String name;


    @GetMapping
    public String get(){
        return name;
    }

}
